#ifndef CPOPUPMENU_H
#define CPOPUPMENU_H

//#define WINVER 0x0500
//#include <windows.h>
#include <stdio.h>
#include <string>
#include "cHwnd.h"
using namespace std;

class cPopupMenu;

struct MenuItem{
    evenementPopup fonction;
    string libelle;
};

class cPopupMenu
{
    public:
        /** Default Hwndconstructor */
        cPopupMenu(cHwnd * _parent);
        void AddItem(string label, evenementPopup fonctionRetour);
        void AddItem(string label, cPopupMenu * sousMenu);
        void AddLine();
        void AddTitre(string titre);
        HMENU GetMenu(){return menu;};
        void Popup();

        /** Default destructor */
        ~cPopupMenu();
    protected:
    private:
        cHwnd * parent;
        int       idmenu;
        HMENU     menu;
};

#endif // CPOPUPMENU_H
